'use strict';
const Controller = require('egg').Controller;


class ClientController extends Controller{
  async login(){
    const { ctx, app } = this;
    const { userName,password } = ctx.request.body;
    //调用service
    const result = await ctx.service.client.login(userName,password);
    ctx.body = result;
  }
  async modifyOrderStatus(){
    const { ctx, app } = this;
    const { orderId,status } = ctx.query;
    const result = await ctx.service.client.modifyOrderStatus(orderId,status);
    ctx.body = result;
  }
}

module.exports = ClientController;